# name : proc freq noninferiority riskdiff
# key : freq.noninf.riskdiff
# contributor: Shuguang Sun
# --
ods output PdiffNoninf = ${9:dtout};
proc freq data = ${1:dtin};
  table ${2:trt} * ${3:resp} / riskdiff(noninf margin = ${4:margin} method = ${5:$$(yas-choose-value '("FM" "SCORE" "HA" "NEWCOMBE" "WALD"))} CL = ${6:$$(yas-choose-value '("AC" "AGRESTICAFFO" "EXACT" "HA" "MN" "NEWCOMBE" "WALD"))})
  alpha = ${7:0.05} nopercent nocol nocum;
  weight ${8:wt};
run;
